.sprite-position(@sprite) {
    @sprite-offset-x: ~`"@{sprite}".split(', ')[2]`;
    @sprite-offset-y: ~`"@{sprite}".split(', ')[3]`;
    background-position: @sprite-offset-x  @sprite-offset-y;
}

.sprite-image(@sprite) {
    @sprite-image: ~`'%=static=%png-sprite/96dpi/' + "@{sprite}".split(', ')[8].replace(']', '').replace(/\'/g, '')`;
    background-image: url(@sprite-image);
}

.sprite-mixin-template(@sprite) {
    .sprite-image(@sprite);
    .sprite-position(@sprite);
    width: ~`"@{sprite}".split(', ')[4]`;
    height: ~`"@{sprite}".split(', ')[5]`;
}

.bg-template(@sprite, @repeat: no-repeat) {
    .sprite-mixin-template(@sprite);
    @sprite-total-width: ~`"@{sprite}".split(', ')[6]`;
    @sprite-total-height: ~`"@{sprite}".split(', ')[7]`;
    background-size: @sprite-total-width, @sprite-total-height;
    background-repeat: @repeat;
}

.highDpiMedia(@sprite) {}
